<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<%@ include file="validProgrammer.jsp" %>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
<script type="text/javascript">
 function checkInput(){
 var time1="0",time2="0",time3="0",timeCfg="000";
   var temp1="0",temp2="0",temp3="0",tempCfg="000";
  
  // document.getElementById("timeCfg").value = timeCfg;
  //  document.getElementById("tempCfg").value = tempCfg;
  
 document.getElementById("form_modifySupplier").submit();
}
 </script>
 <% Supplier supplier= new Supplier();
   if(request.getAttribute("supplier")!=null){
   supplier= (Supplier) request.getAttribute("supplier");
   }
  %>
</head>
<body>

<h1 align="center">商家管理</h1>    
    <h2>修改商家</h2> 
   <form id="form_modifySupplier" action="<%=request.getContextPath()%>/programmer4Jsp";  >
    <input type="hidden" name="affair" value="updateSupplier" /><br/>
      <p style="width: 180px; display: inline; ">电话：</p>   <input type="text" name="telnum"  value="${supplier.telnum}" style="width: 100pt;"/>  <br/>
   <p style="width: 180px; display: inline;  ">密码：</p>   <input type="password" name="secret"  style="width: 100pt;"/> <br/>
   <p style="width: 180px; display: inline; ">名称：</p>  <input type="text" name="name" value="${supplier.name}"  style="width: 200pt;"  /><br/>
    <p style="width: 180px; display: inline; ">地址：</p>  <input type="text" name="address" value="${supplier.address}"  style="width: 200pt;" /><br/>
   <p style="width: 180px; display: inline; ">服务电话：</p>   <input type="text" name="serviceTelnum"  value="${supplier.serviceTelnum}" style="width: 100pt;"/> <br/>
     <p style="width: 180px; display: inline; ">所属业主：</p>  <input type="text" name="owner" value="${supplier.owner}" style="width: 100pt;" /><br/> 
     <p style="width: 180px; display: inline; ">提前分钟下单：</p>  <input type="text" name="minuteMini" value="${supplier.minuteMini}"  style="width: 100pt;" /><br/>
      <p style="width: 180px; display: inline; ">最小起订金额：</p>  <input type="text" name="moneyMini" value="${supplier.moneyMini}" style="width: 100pt;" /><br/>
    <p style="width: 180px; display: inline; ">消费者箱格使用费：</p>  <input type="text" name="boxFeeCu" value="${supplier.boxFeeCu}" style="width: 100pt;" /><br/>
        <p style="width: 180px; display: inline; ">商家箱格使用费：</p>  <input type="text" name="boxFeeSu" value="${supplier.boxFeeSu}" style="width: 100pt;" /><br/>
         <p style="width: 180px; display: inline; ">业主提成比例：</p>  <input type="text" name="rate" value="${supplier.rate}" style="width: 100pt;" /><br/>
         
   <p style="width: 180px; display: inline; ">是否启用：</p> <input  type="radio" id="radio1" name="isAuth" <%  if(supplier.getIsAuth()==1) out.print("checked");%>  value="1">启用       <input  type="radio" id="radio2" name="isAuth"  value="2" <%  if(supplier.getIsAuth()==2) out.print("checked");%> >不启用    <br/>
   
    <input type="button" value="修改" onclick="checkInput();" /> <br/>
    </form> 
    <br/>
    <br/>
    <br/>

</body>
</html>

<script> 
//取出传回来的参数error并与yes比较
  var errorInfoA ='<%=request.getParameter("errorInfo")%>';
  var  errorInfo=decodeURI(errorInfoA);
  if(errorInfo!='null'){
   alert(errorInfo);}

</script>

